void
gsk_render_node_make_immutable (GskRenderNode *node)
{
- GskRenderNode *child;
-
if (!node->is_mutable)
return;
- node->is_mutable = FALSE;
+ node->node_class->make_immutable (node);
- for (child = gsk_render_node_get_first_child (node);
- child != NULL;
- child = gsk_render_node_get_next_sibling (child))
- {
- gsk_render_node_make_immutable (child);
- }
+ node->is_mutable = FALSE;
}
/*< private >
gsk_texture_unref (self->texture);
}
+static void
+gsk_texture_node_make_immutable (GskRenderNode *node)
+{
+}
+
static const GskRenderNodeClass GSK_TEXTURE_NODE_CLASS = {
GSK_TEXTURE_NODE,
sizeof (GskTextureNode),
"GskTextureNode",
- gsk_texture_node_finalize
+ gsk_texture_node_finalize,
+ gsk_texture_node_make_immutable
};
GskTexture *
cairo_surface_destroy (self->surface);
}
+static void
+gsk_cairo_node_make_immutable (GskRenderNode *node)
+{
+}
+
static const GskRenderNodeClass GSK_CAIRO_NODE_CLASS = {
GSK_CAIRO_NODE,
sizeof (GskCairoNode),
"GskCairoNode",
- gsk_cairo_node_finalize
+ gsk_cairo_node_finalize,
+ gsk_cairo_node_make_immutable
};
/*< private >
{
}
+static void
+gsk_container_node_make_immutable (GskRenderNode *node)
+{
+ GskRenderNode *child;
+
+ for (child = gsk_render_node_get_first_child (node);
+ child != NULL;
+ child = gsk_render_node_get_next_sibling (child))
+ {
+ gsk_render_node_make_immutable (child);
+ }
+}
+
static const GskRenderNodeClass GSK_CONTAINER_NODE_CLASS = {
GSK_CONTAINER_NODE,
sizeof (GskRenderNode),
"GskContainerNode",
- gsk_container_node_finalize
+ gsk_container_node_finalize,
+ gsk_container_node_make_immutable
};
/**